
<form id="form_edit"><input type="hidden" name="amount" id="amount" value="{[$result.amount]}" />
<table>
	<tr>
		<td width="20%" align="right">供应商：</td>
		<td width="80%" colspan="3"><input type="text" name="supplier"
				id="supplier" size="20"
				value="{[$result.supplier]}:{[$result.supplier_t]}" title="{[$t.supplier]}"> <a href="javascript:void(0)" id="supplier_x" onclick="Common.toggle(this, '#label_linkman')" class="ui-icon ui-icon-circle-triangle-w" style="display: inline-table"></a></td>
	</tr>
	<tr id="label_linkman">
		<td></td>
		<td colspan="3">
		{[include file="_linkman.tpl"]}				
		</td>
	</tr>	
	<tr>
		<td align="right">事由：</td>
		<td colspan="3"><textarea rows="2" name="name" cols="55">{[$result.name]}</textarea></td>
	</tr>
	<tr>
		<td width="20%" align="right">类型：</td>
		<td width="30%"><select name='type' id='type'>
			{[html_options options=$type_option selected=1]}
		</select></td>
		<td width="20%" align="right">货币：</td>
		<td width="30%"><select name='currency' id='currency'>
			{[html_options options=$currency_option selected=$result.currency]}
		</select></td>
	</tr>
	<tr>
		<td align="right">负责人：</td>
		<td><input type="text" name="emp" id="emp" value="{[$result.emp]}:{[$result.emp_t]}" size="12" title="{[$t.emp_|emp:'负责人']}"> <input type="checkbox"
			name="t_emp" id="t_emp" value="{[$smarty.session.id]}:{[$smarty.session.name]}"> 自己</td>
		<td align="right">填单日期：</td>
		<td><input type="text" name="date" id="date" value="{[$result.date]}" size="12"></td>
	</tr>
	<tr>
		<td align="right">备注：</td>
		<td colspan="3"><textarea rows="2" name="content" cols="55">{[$result.content]}</textarea></td>
	</tr>	
</table>
</form>

<div style="margin-top:10px; width:1024px;float:left;">
<div id="myGrid" style="width:100%;height:160px;"></div>
<table border="0">
	<tr>
		<td width="520" align="right">合计：<label id="label_amount"></label>（小写）</td>
		<td><div id="amount_t">{[$result.amount]}</div></td>
	</tr>
</table>
</div>

<script type='text/javascript'>
var b = $("#currency").find("option:selected").text();
var r = Currency.upper({[$result.amount]}, b, "#label_amount");

data = {[$result.item]};
var type_json = {[$type]};
</script>

<script type="text/javascript" src="js/mold/process/add.js?r={[$smarty.now]}"></script>
